export async function loadConfig() {
  try {
    const response = await fetch("/config.json");
    if (!response.ok) {
      throw new Error("Failed to load config file");
    }
    const config = await response.json();
    return config;
  } catch (error) {
    console.error("Error loading config:", error);
    return {
      apiUrl: "https://api.example.com", // 默认值
    };
  }
}
